package hydrap2p.modulemanager;

import java.io.File;
import java.util.LinkedList;
import java.util.List;

public class ModuleConfig {

	String name;
	String command;
	String realcommand;
	boolean autostart;
	File where;
	String control;
	
	public List<String> needs;		// the modules that it needs
	public List<String> neededby;	// the modules that need this to be running
	public List<String> services;
	
	public ModuleConfig()
	{
		needs=new LinkedList<String>();
		neededby=new LinkedList<String>();
		services=new LinkedList<String>();
	}
	
	@Override
	public boolean equals(Object o)
	{
		if (! (o instanceof ModuleConfig))
			return false;
		ModuleConfig other=(ModuleConfig)o;
		return name.equals(other.name) &&
			   command.equals(other.command) &&
			   where.equals(other.where) &&
			   autostart==other.autostart &&
			   control.equals(other.control);
	}
}
